package com.qqbot.service.group;

import com.qqbot.exception.BusinessException;
import com.qqbot.model.group.Groups;
import com.baomidou.mybatisplus.extension.service.IService;

/**
 * <p>
 * 群信息 服务类
 * </p>
 *
 * @author fyq
 * @since 2023-03-03
 */
public interface GroupsService extends IService<Groups> {

    /**
     * 是否启用
     *
     * @param bot
     * @param groupNo
     * @return
     * @throws BusinessException
     */
    boolean isItEnable(String bot, String groupNo) throws BusinessException;

    /**
     * 保存群信息
     *
     * @param bot
     * @param groupNo
     * @param status
     * @return
     * @throws BusinessException
     */
    boolean saveGroup(String bot, String groupNo, Integer status) throws BusinessException;

    /**
     * 根据群号获取群信息
     *
     * @param bot
     * @param groupNo
     * @return
     * @throws BusinessException
     */
    Groups getByGroupNo(String bot, String groupNo) throws BusinessException;
}
